Page({
  data: {
    announcementlist: [],
  },
  onLoad() {
    this.getAnnouncement();
  },
  // 获取社区公告列表
  async getAnnouncement() {
    // 测试网络请求
    const res = await wx.http({
      url: '/announcement',
    })
    // console.log(res)
    this.setData({
      announcementlist: res.data
    })
  }
})